FROM openjdk:8-jre-alpine

ENV TZ=Asia/Shanghai \
    SPRING_OUTPUT_ANSI_ENABLED=ALWAYS \
    JAVA_OPTS=""

ADD uaa-*.jar /uaa.jar
ADD http://dl.hc-yun.com/soft/wait /wait
ADD entrypoint.sh /usr/local/bin/entrypoint.sh
ADD http://172.31.32.210/xjar-agent-hibernate-v1.0.0.jar /

EXPOSE 8020

ENTRYPOINT ["entrypoint.sh"]

# CMD java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /uaa.jar
CMD java -javaagent:/xjar-agent-hibernate-v1.0.0.jar ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /uaa.jar --xjar.password=mg_zaq1@WSX
